<template>
  <div class="home" id="app">
    <div class="home-left">
      <!-- <h1
        v-for="(item, index) in list"
        :key="index"
        @click="changeNav(item.activeName)"
      >
        {{ item.name }}:
      </h1> --><ul>
      <li><router-link :to="{name:'interest'}">趣味小课</router-link> </li>
      <li><router-link :to="{name:'ready'}">预备课程</router-link> </li>
      <li><router-link :to="{ name:'induction'}">编程入门</router-link> </li>
      <li><router-link :to="{name:'About'}">技术门类+</router-link> </li>
      </ul>
    </div>
    <div class="home-right">
      <router-view />
    </div>
  </div>
</template>
<script>
export default {
  name:'',
  data() {
    return {
      nav: "interest",
      list: [
        { name: "趣味小课", activeName: "interest" },
        { name: "预备课程", activeName: "ready" },
        { name: "编程入门", activeName: "induction" },
        { name: "技术门类+", activeName: "about" },
      ],
    }
  },
  methods: {
    changeNav(name){
      console.log('name==>',name);
      this.name = name
    }
  },
}
</script>
<style lang="scss">
<<<<<<< HEAD

#app{
  width:900px;
  height: 800px;
  margin: auto;
  padding: 0;
  display: flex;
  justify-content: space-between;
}
.nav-left{
  width: 200px;
  height:600px;
  text-align: center;
  margin-left: 30px;
  
}
.nav-left:hover{
    background-color: cadetblue;
    cursor: pointer;
  }
  .nav-right{
    width:800px;
    height: 600px;
    padding: 0;
    background-color: cornflowerblue;
=======
* {
  margin: 0;
  padding: 0;
}

.home {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  background-color: rgb(221, 215, 215);
  display: flex;
  justify-content: space-around;
  align-items: center;
  &-left {
    width: 30%;
    height: 900px;
    background-color: rgb(114, 170, 187);
  }
  li{
    width: 200px;
    height: 200px;
    text-align: center;
    margin-top: 20px;
    font-size:  30px;
  
}
  h1 {
    margin-top: 60px;
  }
  &-right {
    width: 70%;
    height: 100%;
    background-color: pink;
>>>>>>> 6bf8714517698cba3c843e451acfb7d17c339c11
  }
</style>
